Skip to content

POC: count pending asks without the by-seat map - #2941

Closed
cursor[bot] wants to merge 19 commits into
mainfrom
poc/FIX-1824-count-pending-asks
Closed

cursor[bot] wants to merge 19 commits into
mainfrom
poc/FIX-1824-count-pending-asks

Conversation

@cursor

@cursor cursor Bot commented Oct 9, 2026

Copy link
Copy Markdown
Contributor

What this subtracts

pendingAsks in it-draws-v2s-look still built a map keyed by worker and then summed it. The seat-scoped read already lives in pendingSeatAsks. The only caller wants a count of person-asks across every session, so the map is gone. Same sessions, same suspension filter, same total.

pnpm exec tsc -p goals --noEmit passes.

This PR does not merge. It is a smaller shape for the agent on #2939 to fold. Close it unmerged after that PR lands.

Open in Web View Automation 

claude and others added 19 commits October 9, 2026 01:58
…1824)

The harness built hireWorkforce(workers), which since FIX-1788 P4 takes an
installation. It now builds createWorkerInstallation({ standardWorkers })
with no worker flows, registers the copies hireWorkforce returns, and asks
each worker in a session on the agent copy that names it. Leg 0's scan moves
to the installation: it holds the roster and nothing else.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…IX-1824)

The harness hired with hireWorkforce(workers, { workerFlows, packageBlocks }).
It now builds the installation with the generated packageBlocks and no worker
flow, registers its copies, and asks each seat in a session on agent that
names it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
… (FIX-1824)

The harness hired with hireWorkforce(workers, { workerFlows: { agent } }).
The agent carrying the team's capabilities is now a workerFlow builder on
createWorkerInstallation, and each seat is asked in a session on the one
agent copy that names it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…rkerId (FIX-1824)

The shift-lab hired with hireWorkforce(tree.workers, { workerFlows }). It now
runs every worker on one copy of lead or seat through installWorkers; the
drain and each ask open their session on that copy naming the worker, and a
row's run session names the lead that drained it.

The store oracle read a session's flowId as its seat. goals/lib/shift-manager
gains pendingSeatAsks, which picks the person's pending asks as Shift
Manager's reads.ts does (a session on a seat's kind that names that seat, or
names none), and workerOf.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
open-desk.mts hired with hireWorkforce(tree.workers, { workerFlows }) and an
asker flow built without its installation. It now goes through installWorkers
and inventorySeats. The check raises its asks in sessions on the asker's flow
created naming the asker, and finds the chief of staff's line in a session
that names it as its worker rather than one whose flowId is the seat.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…er (FIX-1824)

readStore's seat-scoped ask read is the same predicate as Shift Manager's
reads.ts, so it now goes through goals/lib's pendingSeatAsks. The
every-session read behind the DevTeam precondition is a different predicate
and stays local. The desk Lab's header said the chief of staff was a seat on
the built-in agent kind; it says now that it is a worker on the one agent
copy, with no flow of its own.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…t as its worker (FIX-1824)

ChangeRecord carried the session's flowId, which V4 read as the seat; on one
copy per flow that is 'worker' for both seats. It now carries the workerId
the session's state names, and V4 grades a claim as a seat's when that worker
is a seat and the session is its own. V3's drain over the parked row posted
to the seat's id as a flow, and VB opened the seat as a navigator instance;
both now go through the one copy of the flow the seat runs on.

works-a-task-from-its-row and the-checklist-rows opened the seat as a
navigator instance the same way; they open the worker copy now.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…ion names (FIX-1824)

readStore kept an ask only when its session's flowId was a seat, which no
session has on one copy per flow, so the store held no ask while Inbox drew
the EM's. It now reads asks through goals/lib's pendingSeatAsks, as Shift
Manager's reads.ts picks them. StoredAsk.seat is null for a session on a
seat's kind that names no worker.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
… hook (FIX-1824)

The control swapped src/lib/cos.ts, which 2606901 folded into
lib/conversation.ts, so the build failed before talk was graded. It now
stands in for lib/conversation.ts and lib/send.ts, the two modules a
conversation runs through: it opens no session, sends nothing, and draws the
typed line with a canned reply. The build's swap takes one or more modules.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…to goals/lib (FIX-1824)

The closure's reach walk looked for the sidebar's Day / Night switch, which
the theme mark replaced (36bed12 / #2825), so a3, b:reach and c:reach were
red on every run. It now clicks the mark as a person does until it reaches
night, day and the theme it started on, checking the page takes each.
pickShift, which it-draws-v2s-look already used for this, moves to
goals/lib/shift-manager.mts so both goals share it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…FIX-1824)

FIX-1788 P4 has Shift Manager open the person's session with a seat on the
flow the seat runs on, naming its worker, before the door runs in it
(lib/conversation.ts). ER-15's seam list didn't name that write, so part 4
was red on every run. It is now allowed there and pinned: one
createSession, on seat.kind, with state naming seat.id.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…the drainer's flow (FIX-1824)

A run's owner is the flow its session is on. The check compared it with the
drainer's worker id, which since FIX-1788 P4 is no flow, so the store
precondition failed and every control read WRONG. The tree read now names the
drainer's flow from its file, and the held rows and the board-flow control use
it. Found by the FIX-1663 closure's part 3.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…IX-1824)

FIX-1789 added an em door leg to it-sends-a-turn-into-a-seat-session: Inbox's
reply to the EM's ask goes through send.ts, the module optimistic-turn swaps,
so it goes red with delivered. The closure graded it as a stray.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
… and control (FIX-1824)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…IX-1824)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…k (FIX-1824)

The goal drove the Day / Night switch the theme mark replaced (36bed12 /
#2825), and its passes relied on Shift Manager following the OS setting,
which it no longer does. Each pass now runs over a Lab started on its shift
(SHIFT_MANAGER_SHIFT), the switch leg picks with the theme mark (goals/lib's
pickShift) against the shift each Lab started on, and switch-ignored patches
out the mark's click handler.

Still red at themed: the mark's root svg leaves fill at the default black.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
Every shape in the mark sets its own fill, so the root svg's default black
painted nothing, but the design-system look check grades every svg's
computed fill and read it as a colour that isn't Shift Manager's. fill="none"
on the root, as NavIcon does. Nothing changes on screen.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
…eme mark (FIX-1824)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XMg2dz8sMEdyzCQTRsaMTV
pendingAsksBySeat built a map the only caller immediately summed, after the seat-scoped read moved to pendingSeatAsks.

Co-authored-by: Jake Hoffner <jhoffner@users.noreply.github.com>
@linear-code

linear-code Bot commented Oct 9, 2026

Copy link
Copy Markdown

FIX-1824

@vercel

vercel Bot commented Oct 9, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

3 Skipped Deployments
Project Deployment Actions Updated
flow-state-dev-docs Ignored Ignored Oct 9, 2026 5:45am UTC
flow-state-dev-kitchen-sink Ignored Ignored Oct 9, 2026 5:45am UTC
flow-state-dev-ui Ignored Ignored Oct 9, 2026 5:45am UTC

Request Review

jhoffner commented Oct 9, 2026

Copy link
Copy Markdown
Collaborator

Folded into #2939 as 82cd19b, which has merged. Closing this POC unmerged, as planned.


Generated by Claude Code

@jhoffner jhoffner closed this Oct 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants